package com.wentao.thisService.mapper;

import com.wentao.thisService.model.CompanyCustomEntity;
import com.wentao.thisService.model.entities.IntResultEntity;
import com.wentao.thisService.model.entities.PageEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Mapper
@Repository
public interface CompanyCustomDao {

	public List<CompanyCustomEntity> Search(CompanyCustomEntity entity);
    public List<CompanyCustomEntity> SearchPage(@Param("entityItem") CompanyCustomEntity entityItem, @Param("pageItem") PageEntity pageItem);
    public void Update(@Param("entityItem") CompanyCustomEntity entity, @Param("valueItem") CompanyCustomEntity val);
    public void Insert(CompanyCustomEntity entity);
    
    public List<CompanyCustomEntity> SearchAut(CompanyCustomEntity entity);
    public List<CompanyCustomEntity> SearchPageAut(@Param("entityItem") CompanyCustomEntity entityItem, @Param("pageItem") PageEntity pageItem);
    public void UpdateAut(@Param("entityItem") CompanyCustomEntity entity, @Param("valueItem") CompanyCustomEntity val);
    
    public IntResultEntity Count(CompanyCustomEntity entity);
    public IntResultEntity CountAut(CompanyCustomEntity entity);

    public List<CompanyCustomEntity> SearchByCompanyCode(@Param("companyCode") String companyCode);
    public List<CompanyCustomEntity> SearchByContact(@Param("contact") String contact);
    int UpdateById(CompanyCustomEntity entity);
}